<template>
  <!-- 项目html结构样式 -->
  <div class="jingping">
    <div class="banxin">
      <div class="title tanxin">
        <div class="title_l">
          <img :src="src" alt="" />
          <h2>{{ title }}</h2>
        </div>
        <div class="more" v-show="title !== '积分攻略'">
          <span>更多</span>
          <img src="../../assets/images/home/Arrow.png" alt="" />
        </div>
      </div>
      <!-- <div class="banxin jingping_sp">
        <ul>
          <li v-for="(item, index) in jingpin" :key="index">
            <div class="jingping_sp_t">
              <img :src="item.coverImg" alt="" />
            </div>
            <div class="jingping_sp_b">
              <p>{{ item.name }}</p>
              <span>{{ item.coin }}</span>
              <div>立即兑换</div>
            </div>
          </li>
        </ul>
        <ul class="jifen" v-show="title == '积分攻略'">
          <li>
            <span>签到得鸡腿</span>
            <div>去签到</div>
            <img src="../../assets/images/home/integral-01.png" alt="" />
          </li>
          <li>
            <span>购课得鸡腿</span>
            <div>去购课</div>
            <img src="../../assets/images/home/integral-02.png" alt="" />
          </li>
          <li>
            <span>推荐得鸡腿</span>
            <div>去推荐</div>
            <img src="../../assets/images/home/integral-03.png" alt="" />
          </li>
          <li>
            <span>去做任务得鸡腿</span>
            <div>做任务</div>
            <img src="../../assets/images/home/integral-04.png" alt="" />
          </li>
        </ul>
      </div> -->
    </div>
  </div>
</template>

<script>
export default {
  data() {
    return {
      show: true,
    };
  },
  //获取父级传的参数
  props: ["title", "src", "jingpin"],
};
</script>
 
<style lang = "less" scoped>
/* 引入公共样式 */
@import "../../assets/base.less";
/* html结构样式写入 */
.jingping {
  background-color: #f5f5f5;
}
/* 头部样式 */
.title {
  align-items: center;
  height: 106px;
  .title_l {
    display: flex;
    h2 {
      font-size: 30px;
      font-weight: bold;
      color: @black;
      margin-left: 10px;
    }
  }
  .more {
    span {
      font-size: 16px;
      color: #666666;
      line-height: 23px;
      margin-right: 10px;
    }
  }
}
/* .jingping_sp {
  ul {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    box-sizing: content-box;
    li {
      margin-top: 10px;
      &:last-of-type {
        margin-right: 0;
      }
      .jingping_sp_t {
        width: 285px;
        height: 250px;
        img {
          width: 285px;
          height: 250px;
        }
      }
      .jingping_sp_b {
        width: 285px;
        height: 162px;
        background: #ffffff;
        display: block;
        justify-content: center;
        align-items: center;
        position: relative;
        p {
          position: absolute;
          top: 22px;
          left: 50%;
          transform: translateX(-50px);
        }
        span {
          position: absolute;
          top: 56px;
          left: 50%;
          transform: translateX(-30px);
        }
        div {
          width: 100px;
          height: 36px;
          border: 1px solid #0a328e;
          position: absolute;
          bottom: 32px;
          left: 50%;
          transform: translateX(-50px);
          text-align: center;
          line-height: 36px;
          cursor: pointer;
        }
        div:hover {
          background-color: #0a328e;
          color: white;
        }
      }
    }
  }
  .jifen {
    li {
      width: 285px;
      height: 168px;
      position: relative;
      overflow: hidden;
      margin-bottom: 10px;
      z-index: 1;
      span {
        position: absolute;
        margin-top: 43px;
        left: 20px;
        font-size: 30px;
        font-family: SourceHanSansSC;
        font-weight: bold;
        color: #ffffff;
        line-height: 23px;
        z-index: 1;
      }
      div {
        position: absolute;
        margin-top: 91px;
        left: 21px;
        width: 96px;
        height: 27px;
        border: 1px solid #ffffff;
        text-align: center;
        line-height: 27px;
        font-weight: bold;
        color: white;
        z-index: 1;
        cursor: pointer;
      }
    }
    li:hover {
      img {
        transform: scale(1.2);
        z-index: 999;
      }
    }
  }
} */
</style>